Skip to content

Improve paper glossary selection and Obsidian workflow#11

Draft
jiang4wqy wants to merge 1 commit into
917Dhj:developfrom
jiang4wqy:codex/paper-glossary-selection-gate
Draft

Improve paper glossary selection and Obsidian workflow#11
jiang4wqy wants to merge 1 commit into
917Dhj:developfrom
jiang4wqy:codex/paper-glossary-selection-gate

Conversation

@jiang4wqy

Copy link
Copy Markdown

Summary

  • enforce a preview-and-wait selection gate before glossary or article writes across terminal, Codex, and Claude Code hosts
  • add one-time device-local Obsidian vault configuration, same-vault article validation, library inventory, and additive create/enrich/reuse behavior
  • bind proposal, semantic review, user selection, inventory, writer mappings, and article linking with fail-closed provenance and SHA-256 checks
  • add atomic first-safe-occurrence article linking with protected Markdown/HTML contexts, including linkable visible text in simple emphasis tags
  • keep the companion skill self-contained and dependency-free; DeepPaperNote workflows and root plugin manifests remain unchanged

Why

The previous flow could proceed directly from a broad request to generated glossary notes, which skipped the reader's intended term-selection step. It also lacked a portable per-device glossary destination, robust reuse of a central Obsidian term library, authenticated cross-stage artifacts, and reliable article outbound links.

This update makes selection mandatory by default. 全部写入 applies only to the immediately preceding numbered shortlist, and stale proposals or changed source/article content stop before writes.

User impact

  • users configure an Obsidian glossary directory once per device
  • every run shows the resolved glossary and explicit article paths before selection
  • existing complete notes are reused, thin notes are enriched only in missing fields, and new notes are created in one preflighted batch
  • selected terms receive first-safe-occurrence article links and glossary notes receive article backlinks
  • local post-selection CLI work is sub-second in the verified 15-term run; model review and content generation remain the dominant latency

Validation

  • 81 passed for the linker suite
  • 318 passed for skills/paper-glossary/tests
  • 677 passed for the repository test suite
  • 24 passed boundary retest after the final documentation whitespace cleanup
  • independent narrow code review: CLEAN
  • local Obsidian smoke run: 15 notes written, 15/15 article links present, 15/15 glossary lint checks passed
  • staged diff limited to skills/paper-glossary/; no new dependency or plugin-manifest change

@jiang4wqy

Copy link
Copy Markdown
Author

CI progress update

  • macOS: passed
  • Windows: 4 failures in the root tests/test_common.py; no paper-glossary test failed

The failures come from base commit 26fbcef, added after this branch point. Its new safe_relative_path_parts() validation checks Path(raw).is_absolute(), PureWindowsPath(raw).is_absolute(), and windows_path.drive, but on Python 3.11/Windows the value /outside has:

Path.is_absolute = False
PureWindowsPath.is_absolute = False
drive = ""
root = "\\"

Therefore /outside is accepted even though the accompanying base tests require it to be rejected. The focused upstream fix is to include windows_path.root (or an equivalent rooted-path check) in that rejection condition.

This PR remains intentionally limited to skills/paper-glossary/, so it does not modify the DeepPaperNote canonical workflow to mask a base-branch failure. Once the base fix lands, the Windows check can be rerun without changing this PR's companion-skill scope.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant